package org.linys.service.station;

import java.util.List;

import org.linys.dao.station.StationDAO;
import org.linys.model.station.Station;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@Service
public class StationServ {
	
	private StationDAO stationDAO;
	
	public int count(Station station) {
		return stationDAO.count(station);
	}
	public List<Station> view(Station station, Integer start, Integer rows) {
		return stationDAO.view(station,start,rows);
	}
	
	
	public StationDAO getStationDAO() {
		return stationDAO;
	}
	@Autowired
	public void setStationDAO(StationDAO stationDAO) {
		this.stationDAO = stationDAO;
	}
	public int save(Station station) {
		return stationDAO.save(station);
	}
	public int update(Station station) {
		return stationDAO.update(station);
	}
	public void deleteByID(Integer id) {
		stationDAO.deleteByID(id);
	}
	public int countChoose(Station station) {
		return stationDAO.countChoose(station);
	}
	public List<Station> viewChoose(Station station, Integer start, Integer rows) {
		return stationDAO.viewChoose(station,start,rows);
	}

	

}
